using System.Collections.Generic;
using System.Linq;
using TickSharp.Core.Infrastructure.Repositories;
using TickSharp.Core.Model;
using Xunit;

namespace TickSharp.Tests.IntegrationTests.Infrastructure
{
    public class TaskRepositoryTester : RepositoryTesterBase
    {
        [Fact]
        public void ListReturnsTasksForProject()
        {
            TaskRepository taskRepository = new TaskRepository(GetApiConnectionInfo());

            IEnumerable<Task> tasks = taskRepository.List(SuperProject);
            
            Assert.Equal(2, tasks.Count());
        }
    }
}